package com.google.p.code.springscim.client.schema.model;

import java.util.ArrayList;
import java.util.List;

public class ResourceAttribute {
    
    /*
     * The attribute's name.
     */
    private String name;
    
    /*
     * The attribute's data type; e.g., String.
     */
    private String type;
    
    /*
     * Boolean value indicating the attribute's plurality.
     */
    private boolean multiValued;
    
    /*
     * String value specifying the child XML element name; e.g., the 'emails'
     * attribute value is 'email', 'phoneNumbers', is 'phoneNumber'. REQUIRED
     * when the multiValued attribute value is true otherwise this attribute
     * MUST be omitted.
     */
    private String multiValuedAttributeChildName;
    
    /*
     * The attribute's human readable description. When applicable Service
     * Providers MUST specify the description specified in the core schema
     * specification.
     */
    private String description;
    
    /*
     * The attribute's associated schema; e.g., urn:scim:schemas:core:1.0.
     */
    private String schema;
    
    /*
     * A Boolean value that specifies if the attribute is mutable.
     */
    private boolean readOnly;
    
    /*
     * A Boolean value that specifies if the attribute is required.
     */
    private boolean required;
    
    /*
     * A Boolean value that specifies if the String attribute is case sensitive.
     */
    private boolean caseExact;
    
    /**
     * The following multi-valued attributes are defined. There are no canonical
     * type values defined and the primary value serves no useful purpose.
     */
    private List<ResourceSubAttribute> subAttributes = new ArrayList<ResourceSubAttribute>();
    
    public String getName() {
        return name;
    }
    
    public void setName(String name) {
        this.name = name;
    }
    
    public String getType() {
        return type;
    }
    
    public void setType(String type) {
        this.type = type;
    }
    
    public boolean isMultiValued() {
        return multiValued;
    }
    
    public void setMultiValued(boolean multiValued) {
        this.multiValued = multiValued;
    }
    
    public String getMultiValuedAttributeChildName() {
        return multiValuedAttributeChildName;
    }
    
    public void setMultiValuedAttributeChildName(String multiValuedAttributeChildName) {
        this.multiValuedAttributeChildName = multiValuedAttributeChildName;
    }
    
    public String getDescription() {
        return description;
    }
    
    public void setDescription(String description) {
        this.description = description;
    }
    
    public String getSchema() {
        return schema;
    }
    
    public void setSchema(String schema) {
        this.schema = schema;
    }
    
    public boolean isReadOnly() {
        return readOnly;
    }
    
    public void setReadOnly(boolean readOnly) {
        this.readOnly = readOnly;
    }
    
    public boolean isRequired() {
        return required;
    }
    
    public void setRequired(boolean required) {
        this.required = required;
    }
    
    public boolean isCaseExact() {
        return caseExact;
    }
    
    public void setCaseExact(boolean caseExact) {
        this.caseExact = caseExact;
    }
    
    public List<ResourceSubAttribute> getSubAttributes() {
        return subAttributes;
    }
    
    public void setSubAttributes(List<ResourceSubAttribute> subAttributes) {
        this.subAttributes = subAttributes;
    }
    
}
